libxl: strdup disk path before put it in qemu args array.
authorAnthony PERARD <anthony.perard@citrix.com>
Mon, 13 Dec 2010 17:59:02 +0000 (17:59 +0000)
committerAnthony PERARD <anthony.perard@citrix.com>
Mon, 13 Dec 2010 17:59:02 +0000 (17:59 +0000)
commit5b4d52decb7ca0758ae0e79b67548dd6adbbf2f0
tree748043be5e8187b7e37fb33cb37f5915d8c84150
parent3c97df22bee25ff0fc3d7f3b8642a5aba076b62b
libxl: strdup disk path before put it in qemu args array.

In libxl_build_device_model_args_new, the path to the disk image are
freeed before there was actually use to make the arguments list of Qemu.
The patch strdups it.

This patch also changes argv[0] of the device model.
Now, it is the conventional argv[0], so is value come from
info->device_model.

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
committer: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
---
 tools/libxl/libxl.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)
tools/libxl/libxl.c